
  import {frameInRoutes} from "@/router/routes";
  import layoutHeaderAside from "@/views/layout/header-aside";
  import utils from '@/assets/utils/zhzf-util';
export default {
  methods: {
    addTabPage(title,path,name,view,param) {
      // this.detailVisible = true;
      // this.$refs.detailFrom.initPage(row);
      let pageTitle = title;
      let rpath = path;
      let rname = name;
      let isExits = frameInRoutes[0].children.some(item => item.path == rpath);
    if (!isExits) {
      const route = [
        {
          path: "/",
          component: layoutHeaderAside,
          children: [
            {
              path: rpath,
              name: rname,
              component: view,
              meta: {title: pageTitle}
            }
          ]
        }
      ];
      this.$router.addRoutes(route);
      utils.pushRouterStatus(frameInRoutes, this.$route, route)
      // 更新标签页池
      this.pageInit(frameInRoutes);
    }
      // 跳转
      this.$router.push({name: rname, params: param, path:path});
    },
  }
}
